package com.lh.recallbootrabbitmq.exception;


import com.lh.recallbootrabbitmq.constants.Constants;

public class RabbitMQExceptionUtils {
    /**
     * 实例化RabbitMQException的异常
     *
     * @param errMsg
     * @return
     */
    public static RabbitMQException throwRabbitMQException(String errMsg) {
        return new RabbitMQException(errMsg);
    }

    /**
     * 实例化默认的RabbitMQException的异常
     *
     * @return
     */
    public static RabbitMQException throwRabbitMQException() {
        return new RabbitMQException(Constants.PARAMETER_DEFAULT_NOT_NULL_EXCEPTION_MSG);
    }
}
